#!/usr/bin/env python
# -*- coding: utf-8 -*-
# @Time    : 2022/10/14 14:09
# @Author : 闫峰
# @File    : ebay_listing_management_page_locs.py
from selenium.webdriver.common.by import By


class Ebay_Listing_Manegement_Page_Locs:

    """
    Ebay Listing管理页面iframeSubMenu

    """
    #内嵌页定位
    iframe_iframeSubMenu  = (By.XPATH,'//*[@id="iframeSubMenu"]')
    #草稿按钮
    draft_button = (By.XPATH,'//*[@id="div_listinglist"]/div[1]/div[3]/ul/li[1]/a/span[1]')

    """
    TheDraft_Fream页面
    """
    iframe_TheDraft_Fream = (By.XPATH,'//*[@id="TheDraft_Fream"]')
    #Listing管理按钮
    listing_management_button = (By.XPATH,'//*[@id="divTop"]/div/a[1]/span/span[1]')

    #创建Listing按钮
    create_listing_button = (By.XPATH,'//*[@id="listingmenu1"]/div[2]/div[1]')



    """
    OpenIframeWin 页面(创建Listing)
    """
    #内嵌页
    iframe_OpenIframeWin = (By.XPATH,'//*[@id="OpenIframeWin"]')
    #站点下拉按钮
    site_drop_down_button = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[3]/td[2]/span/span/a')
    #来源渠道账号下拉按钮
    lyqd_user_drop_down_buttton = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[4]/td[2]/span/span/a')
    #启用定时刊登勾选框
    enable_scheduled_publishing_select = (By.XPATH,'//*[@id="ckEnableTimerPosting"]')
    #定时刊登日期输入框
    scheduled_publishing_input  = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[5]/td[2]/span[3]/input[1]')
    #刊登产品输入框
    publish_products_input = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[6]/td[2]/span[1]/input[1]')
    #加载刊登产品按钮
    load_publish_products_input_button = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[6]/td[2]/a[1]/span/span[1]')
    #生成渠道SKU按钮
    generate_channel_SKU = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[7]/td[2]/a/span/span[1]')
    #用于获取值的元素
    channel_SKU_value = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[7]/td[2]/span/input[2]')
    #渠道SKU输入框
    channel_SKU_input = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[7]/td[2]/span/input[1]')
    #产品标题输入框
    product_title_input = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[9]/td[2]/span[1]/input[1]')
    #产品第一分类输入框
    first_classification_of_products_input = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[11]/td[2]/span[1]/input[1]')
    #加载产品第一分类按钮
    load_first_classification_of_products_input_button = (By.XPATH,'//*[@id="fmPro"]/table[1]/tbody/tr[6]/td[2]/a[1]/span')
    #设置为"Does not apply"勾选
    Does_not_apply_select = (By.XPATH,'//*[@id="rdmDefault"]')
    #一口价输入框
    price_input = (By.XPATH,'//*[@id="fixPrice"]/td[2]/span/input[1]')
    #产品描述tab
    product_description_button = (By.XPATH,'//*[@id="tab"]/div/ul/li[3]')
    #描述模板下拉按钮
    description_template_drop_down_button = (By.XPATH,'/html/body/div[1]/div[2]/div/div/div/div[1]/div[3]/table/tbody/tr[1]/td[2]/span/input[1]')
    #产品详细描述输入框
    detailed_product_description_input = (By.XPATH,'//td[@style="width: 100%;"]//iframe')
    #关联营销按钮
    related_marketing_button = (By.XPATH,'//*[@id="tab"]/div/ul/li[8]')
    #模板名称按钮
    related_marketing_template_name_drop_down_button = (By.XPATH,'//*[@id="divmarketing"]/div/table/tbody/tr[1]/td[2]/span/span/a')

    #运输信息按钮
    transportation_information_button = (By.XPATH,'//*[@id="tab"]/div/ul/li[5]')
    #运输方式模板下拉按钮
    transportation_mode_template_drop_down_button = (By.XPATH,'//*[@id="tab_Shipping"]/table[1]/tbody/tr/td[2]/span/span/a')
    #保存草稿
    save_draft_button = (By.XPATH,'/html/body/div[1]/div[3]/div/a[1]/span/span[1]')